#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>
#include <string.h>
int main()
{
	int n = 0;
	int flag = 0;
	int j = 1;
	scanf("%d", &flag);
	for (n = 1; n <= flag; n++)
	{
		j = j*n;
	}
	printf("%d", j);
	return 0;
}